Skip to content

Add tests for string clip edge cases#45

Merged
NailxSharipov merged 2 commits intoiShape-Rust:mainfrom
mikhailofff:main
Jan 27, 2026
Merged

Add tests for string clip edge cases#45
NailxSharipov merged 2 commits intoiShape-Rust:mainfrom
mikhailofff:main

Conversation

@mikhailofff
Copy link
Contributor

Summary

#33

Changes

Added corner-case tests for string clip

Testing

  • cargo test
  • cargo fmt
  • cargo clippy

Checklist

  • Added tests for new behavior or bug fixes
  • Updated docs/examples if needed

@codecov
Copy link

codecov bot commented Jan 27, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@NailxSharipov
Copy link
Member

Everything is fine, except for the small rename wish.

@mikhailofff
Copy link
Contributor Author

Hi, @NailxSharipov. Could you put it in more detail?

@NailxSharipov
Copy link
Member

Yes.

let rect = vec![
    IntPoint::new(-2, -2),
    IntPoint::new(2, -2),
    IntPoint::new(3, 0),
    IntPoint::new(-3, 0),
];

this contour is not a rect, it is a trapezoid!

just rename rect to contour or path so it will be:

let contour = vec![
    IntPoint::new(-2, -2),
    IntPoint::new(2, -2),
    IntPoint::new(3, 0),
    IntPoint::new(-3, 0),
];

@mikhailofff
Copy link
Contributor Author

Ahh...for sure


#[test]
fn test_shared_vertices_1() {
let rect = vec![
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

better to rename it to something neutral like path_0. It's not a rect right now

@NailxSharipov NailxSharipov merged commit 6d0fa3b into iShape-Rust:main Jan 27, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants